package com.itheima.interface_case.students_manager;

import java.util.ArrayList;

public abstract class StudentOperator implements ClassManagerImpl {
    ArrayList<Student> students = new ArrayList<>();

    public StudentOperator() {
    }

    public StudentOperator(ArrayList<Student> students) {
        this.students = students;
    }

    public ArrayList<Student> getStudents() {
        return students;
    }

    public void setStudents(ArrayList<Student> students) {
        this.students = students;
    }

    public int addStudent(Student student) {
        this.students.add(student);
        return this.students.size();
    }
}
